<?xml version='1.0' encoding='UTF-8' ?>
<f:view xmlns="http://www.w3.org/1999/xhtml" 
        xmlns:f="http://java.sun.com/jsf/core"
        xmlns:h="http://java.sun.com/jsf/html"
        xmlns:ui="http://java.sun.com/jsf/facelets"
        xmlns:p="http://primefaces.org/ui"
        xmlns:pm="http://primefaces.org/mobile"
        contentType="text/html">
    
    <pm:page title="MyTV" >
        <f:facet name="postinit">
            <script type="text/javascript">
                jQuery(document).ready(function(){
                    //Home Page icon
                    //jQuery('head').append('<link rel="apple-touch-icon" href="images/logo.jpg"/>');
                    //Splash screen for iPhone
                    //jQuery('head').append('<link rel="apple-touch-startup-image" href="resources/mail.png"/>');
                    //This will hide the browser address bar
                    jQuery('head').append('<meta name="apple-mobile-web-app-capable" content="yes" />');
                    jQuery('head').append('<meta name="viewport" content="initial-scale=1.0, user-scalable=no, width=device-width"/>');
                    //Adds a custom style sheet
                    jQuery('head').append('<link href="resources/style.css" rel="stylesheet" type="text/css"/>');
                });
            </script>
        </f:facet>
        
        <pm:view id="configView">
            <pm:header title="MyTV">
                <f:facet name="left">
                    <p:button value="#{lang.back}" icon="back" href="#{configBean.rootPath}/index.xhtml"/>
                </f:facet>
            </pm:header>
            <pm:content>
                <h:form>
                    <h:panelGroup>
                        <h:outputLabel for="globalDir" value="#{lang.path}"/>
                        <h:inputText id="globalDir" value="#{configBean.path.value}" />
                        <p:watermark for="globalDir" value="#{lang.path}"/>
                        
                        <h:outputLabel for="playerDir" value="#{lang.player}"/>
                        <h:inputText id="playerDir" value="#{configBean.player.value}" />
                        <p:watermark for="playerDir" value="#{lang.player}"/>
                        
                        <p:separator />
                        <p:commandButton value="#{lang.save}" icon="save" update="@form" actionListener="#{configBean.save}"/>
                    </h:panelGroup>
                </h:form>
            </pm:content>
        </pm:view>
        
    </pm:page>
</f:view>